import request from '@/utils/request'

// 查询售后列表列表
export function listOrder(query) {
  return request({
    url: '/mes/aft/order/list',
    method: 'get',
    params: query
  })
}

// 查询售后列表详细
export function getOrder(aftId) {
  return request({
    url: '/mes/aft/order/' + aftId,
    method: 'get'
  })
}

// 新增售后列表
export function addOrder(data) {
  return request({
    url: '/mes/aft/order',
    method: 'post',
    data: data
  })
}

// 修改售后列表
export function updateOrder(data) {
  return request({
    url: '/mes/aft/order',
    method: 'put',
    data: data
  })
}

// 删除售后列表
export function delOrder(aftId) {
  return request({
    url: '/mes/aft/order/' + aftId,
    method: 'delete'
  })
}

// 查询快递
export function getQueryTrackReq(data) {
  return request({
    url: '/mes/aft/order/getQueryTrackReq',
    method: 'post',
    data: data
  })
}

// 测试
export function getTra(aftId) {
  return request({
    url: '/mes/aft/order/tra/'+ aftId,
    method: 'get'
  })
}
